//Figure 1==============================================================
*title: "Long-term Bonds over Gross Debt (20 countries, 1999-2024)"
use "Data/cleaned_data/CountryGrossDebtSecurityLongTerm.dta", clear
tostring(year), replace
merge 1:1 country_id year using "Data/cleaned_data/CountryGrossDebt.dta"
destring year, replace
	//Analysis: LongtermbondsOvergross
{
//Dropping countries
	*drop the euroarea rows
drop if inlist(country, "Euro area (EA11-1999, EA12-2001, EA13-2007, EA15-2008, EA16-2009, EA17-2011, EA18-2014, EA19-2015, EA20-2023)", "Euro area - 12 countries (2001-2006)", "Euro area - 19 countries  (2015-2022)", "Euro area – 20 countries (from 2023)", "European Union - 27 countries (from 2020)")
drop if inlist(country, "Albania", "Bosnia and Herzegovina", "Iceland", "Kosovo", "Liechtenstein")
drop if inlist(country, "Montenegro", "North Macedonia", "Norway", "Serbia", "Switzerland", "Türkiye")
distinct country
	*earliest start date is 1999
	*cut all observations before year 1998
drop if year < 1998
	*cut all observations by countries' join date
drop if inlist(country, "Cyprus", "Czechia", "Estonia", "Hungary", "Latvia") & year < (2004-1)
drop if inlist(country, "Lithuania", "Malta", "Poland", "Slovakia", "Slovenia") & year < (2004-1)
drop if inlist(country, "Bulgaria", "Romania") & year < (2007-1)
drop if inlist(country, "Croatia") & year < (2014-1)
drop if inlist(country, "United Kingdom") & year > 2019
	*cut all non-Euro-using countries
drop if inlist(country, "Bulgaria", "Czechia", "Denmark", "Hungary", "Poland", "Romania", "Sweden", "United Kingdom")
	*certain countries didn't start using euro immediately after joining the EU
drop if inlist(country, "Greece") & year < (2001-1)
drop if inlist(country, "Solvenia") & year < (2007-1)
drop if inlist(country, "Cyprus", "Malta") & year < (2008-1)
drop if inlist(country, "Solvakia") & year < (2009-1)
drop if inlist(country, "Estonia") & year < (2011-1)
drop if inlist(country, "Latvia") & year < (2014-1)
drop if inlist(country, "Lithuania") & year < (2015-1)
drop if inlist(country, "Croatia") & year < (2023-1)
	*estonia wasn't in the long-term bond market until 2021
drop if inlist(country, "Estonia") & year < (2021)
}
gen LongtermbondsOvergross = debtltfv/debt
destring(year), replace
xtset country_id year
summarize LongtermbondsOvergross, detail
twoway ///
    (scatter LongtermbondsOvergross year if !missing(LongtermbondsOvergross), ///
        msize(vsmall) mcolor(gs10)) ///
    (function y = 0.6383581, range(year) lcolor(red) lpattern(dash) lwidth(medium)), ///
    xtitle("Year") ytitle("Long-term over Gross Debt") ///
    graphregion(color(white)) legend(position(6) ring(0) order(2 "Threshold: 75% of obs > 0.638")) ///
    aspectratio(0.5)
graph export "Output\Figure1.pdf", replace

//Figure 2==============================================================
*title: "Annual Default Probability (20 countries, 1999-2024)"
use "Data/cleaned_data/Master_1.dta", clear
gen ylow = 0
gen yhigh = 0.6
twoway ///
	(rarea ylow yhigh year if inrange(year, 2010, 2014), color(gs14) lcolor(gs14) sort) ///
    (scatter defaultRateAvgAnnual year if assistanceYear != 1 & inrange(year, 1999, 2024), mcolor(gs10) msize(vsmall)) ///
    (scatter defaultRateAvgAnnual year if assistanceYear == 1, ///
        mcolor(red) msize(small)), ///
    xtitle("Year") ///
    ytitle("Default Probability") ///
    graphregion(color(white)) ///
    legend(off) ///
    aspectratio(0.5)	
graph export "Output\Figure2.pdf", replace
	
//Figure 3 ==============================================================
*title: "Annual Longterm Bond Interest Rate (5 countries that received financial assistance)"
use "Data/cleaned_data/Master_1.dta", clear
{
twoway ///
    (scatter sInterestRateAvgAnnual year if country == "Cyprus" & assistanceYear != 1, ///
        mcolor(blue) msize(vsmall)) ///
    (scatter sInterestRateAvgAnnual year if country == "Greece" & assistanceYear != 1, ///
        mcolor(green) msize(vsmall)) ///
    (scatter sInterestRateAvgAnnual year if country == "Ireland" & assistanceYear != 1, ///
        mcolor(orange) msize(vsmall)) ///
    (scatter sInterestRateAvgAnnual year if country == "Portugal" & assistanceYear != 1, ///
        mcolor(purple) msize(vsmall)) ///
    (scatter sInterestRateAvgAnnual year if country == "Spain" & assistanceYear != 1, ///
        mcolor(cyan) msize(vsmall)) ///
    (scatter sInterestRateAvgAnnual year if country == "Cyprus" & assistanceYear == 1, ///
        mcolor(red) msize(small)) ///
    (scatter sInterestRateAvgAnnual year if country == "Greece" & assistanceYear == 1, ///
        mcolor(red) msize(small)) ///
    (scatter sInterestRateAvgAnnual year if country == "Ireland" & assistanceYear == 1, ///
        mcolor(red) msize(small)) ///
    (scatter sInterestRateAvgAnnual year if country == "Portugal" & assistanceYear == 1, ///
        mcolor(red) msize(small)) ///
    (scatter sInterestRateAvgAnnual year if country == "Spain" & assistanceYear == 1, ///
        mcolor(red) msize(small)) ///
    (line sInterestRateAvgAnnual year if country == "Cyprus", ///
        lcolor(blue%50) lwidth(medium)) ///
    (line sInterestRateAvgAnnual year if country == "Greece", ///
        lcolor(green%50) lwidth(medium)) ///
    (line sInterestRateAvgAnnual year if country == "Ireland", ///
        lcolor(orange%50) lwidth(medium)) ///
    (line sInterestRateAvgAnnual year if country == "Portugal", ///
        lcolor(purple%50) lwidth(medium)) ///
    (line sInterestRateAvgAnnual year if country == "Spain", ///
        lcolor(cyan%50) lwidth(medium)), ///
    ///
    xtitle("Year") ///
    ytitle("Sovereign Debt Interest Rate") ///
    graphregion(color(white)) ///
    legend(order(11 "Cyprus" 12 "Greece" 13 "Ireland" 14 "Portugal" 15 "Spain") ) ///
    aspectratio(0.5)
}
graph export "Output\Figure3.pdf", replace

//Figure 4================================================
*title: "Interest Rate to GDP Growth Rate Ratio (rgRatio) and Debt Unsustainability Threshold (ζ) (20 countries, 1999-2024)"
use "Data/cleaned_data/Analysis_3.dta", replace
sort rgRatioThreeYearForward
twoway ///
    (scatter rgRatioThreeYearForward year, ///
        msize(vsmall) mcolor(gs10)) ///
    (function y = 2.3563061, range(year) lcolor(red) lpattern(dash) lwidth(medium)), ///
    xtitle("Year") ytitle("rgRatio (Three-Year-Forward Moving Window)") ///
    graphregion(color(white)) legend(position(1) ring(0) size(small) cols(1) order(2 "z Threshold: 2.5% of obs > 2.3563061")) aspectratio(0.5)
graph export "Output\Figure4.pdf", replace

//Table 1==================================================
*title "Caliberated Parameters (%, for Germany, Italy, and Greece, 2010-2015) Sovereign Bond Rate, Default Rate, Assistance Amount, and Debt Unsustainability Threshold"
use "Data/cleaned_data/Analysis_3.dta", replace

gen assistanceAmountToDebt = assistanceAmount/debt
keep if inlist(country, "Germany", "Italy", "Greece") & inrange(year, 2010, 2015)
keep year country country_id sInterestRateAvgAnnual defaultRateAvgAnnual assistanceAmountToDebt
*making things a ratio
replace sInterestRateAvgAnnual = sInterestRateAvgAnnual*100
replace defaultRateAvgAnnual = defaultRateAvgAnnual*100
replace assistanceAmountToDebt = assistanceAmountToDebt*100

label variable sInterestRateAvgAnnual "Interest Rate"
label variable defaultRateAvgAnnual "Default Rate"
*the ratio is the estimated amount of assistance received in year t over the reported amount of outstanding debt
label variable assistanceAmountToDebt "Assistance to Debt Ratio"

table year country, ///
    statistic(mean sInterestRateAvgAnnual) ///
    statistic(mean defaultRateAvgAnnual) ///
    statistic(mean assistanceAmountToDebt) ///
	nformat(%9.2f) ///
    nototals 
collect export "Output\Table1.tex", replace
*this table is later edited in latex
	

	
	
	
	
	
	

//Analysis section==========================

//Figure 5 ==============================================================
*title "Debt and Estimated Debt Level to GDP, by country (20 countries, 1999-2024)"
use "Data\cleaned_data\Analysis_3.dta", clear
	*estimated debt level compared to debt statistics
	*this may look bad as some counties have significantly higher estimated debt level
	*Luxembourg has small, negative debt level estimation since 2000 due to persistant primary fiscal surplus and outstanding debt sustinability conditions (rgRatio significantly lower than 1), (?) meaning that Luxembourg experiences no negative effects from debt issuance. 
/* a simple plotting:
twoway (line debt year, lcolor(blue) lpattern(solid)) ///
       (line w year, lcolor(red) lpattern(dash)), ///
       by(country, legend(off)) ///
       legend(order(1 "Debt" 2 "W")) ///
       xlabel(2000(5)2025) ylabel(, angle(0))
	//but in perspective of gdp, our estimated w is not a big increase from debt
*/

gen wToGDP = w / gdp
gen debtToGDP = debt / gdp
twoway ///
    (line debtToGDP year, lcolor(blue) lpattern(solid)) ///
    (line wToGDP year, lcolor(red) lpattern(solid)), ///
    by(country, yrescale style(altleg)) ///
	legend(position(9) cols(2) order(1 "Debt to GDP" 2 "Estimated Debt Level to GDP"))xlabel(2000(10)2025) ///
    ylabel(0(2)6, angle(0)) ///
	xtitle("Year") ///
	ytitle("Reported & Estimated Debt Over GDP")
    
graph export "Output\Figure5.pdf", replace
	*how much more, on average, is the w than debt?
gen diff = w/debt -1
summarize diff
gen diff2 = diff if !inlist(country, "Cyprus", "Greece", "Ireland", "Portugal")
summarize diff2
	
//Figure 6 ==============================================================
*title ""
	*several countries have very high debt level, there are two reasons: a) phi is abnormally high due to default rate being high; b) debt sustinability pruduct term being significantly larger than 1
	*average default rate
use "Data\cleaned_data\Analysis_2.dta", clear
bysort year (country): egen defaultRateAvgAnnualAllCountries = mean(defaultRateAvgAnnual)

{
	twoway ///
    (scatter defaultRateAvgAnnual year if country == "Cyprus" & inrange(year, 1999, 2024), ///
        mcolor(blue) msize(vsmall)) ///
    (scatter defaultRateAvgAnnual year if country == "Greece" & inrange(year, 1999, 2024), ///
        mcolor(green) msize(vsmall)) ///
    (scatter defaultRateAvgAnnual year if country == "Portugal" & inrange(year, 1999, 2024), ///
        mcolor(purple) msize(vsmall)) ///
    (scatter defaultRateAvgAnnual year if country == "Italy" & inrange(year, 1999, 2024), ///
        mcolor(orange) msize(vsmall)) ///
	(scatter defaultRateAvgAnnualAllCountries year if inrange(year, 1999, 2024), ///
        mcolor(gs8) msize(vsmall)) ///
    (line defaultRateAvgAnnual year if country == "Cyprus" & inrange(year, 1999, 2024), ///
        lcolor(blue%50) lwidth(medium)) ///
    (line defaultRateAvgAnnual year if country == "Greece"& inrange(year, 1999, 2024), ///
        lcolor(green%50) lwidth(medium)) ///
    (line defaultRateAvgAnnual year if country == "Portugal"& inrange(year, 1999, 2024), ///
        lcolor(purple%50) lwidth(medium)) ///
	(line defaultRateAvgAnnual year if country == "Italy"& inrange(year, 1999, 2024), ///
        lcolor(orange%50) lwidth(medium)) ///
	(line defaultRateAvgAnnualAllCountries year if inrange(year, 1999, 2024), ///
        lcolor(black%50) lwidth(medium)), ///
    xtitle("Year") ///
    ytitle("Sovereign 10yr Bond Default Rate") ///
    graphregion(color(white)) ///
    legend(order(1 "Cyprus" 2 "Greece" 3 "Portugal" 4 "Italy" 5 "EU Average") ) ///
	xlabel(2000(10)2025) ///
    aspectratio(0.5)
}
graph export "Output\Figure6.pdf", replace

//Figure 7 ==============================================================
*title "Country and EU Average Debt Sustainability Ratio Trend (4 countries, 1999-2024)"
*6a doesn't explain portugal and italy's high debt level estimation, this does: 
use "Data\cleaned_data\Analysis_3.dta", clear
bysort year (country): egen rgRatioAvg = mean(rgRatio)

{
	twoway ///
    (scatter rgRatio year if country == "Cyprus" , ///
        mcolor(blue) msize(vsmall)) ///
    (scatter rgRatio year if country == "Greece" , ///
        mcolor(green) msize(vsmall)) ///
    (scatter rgRatio year if country == "Portugal" , ///
        mcolor(purple) msize(vsmall)) ///
    (scatter rgRatio year if country == "Italy" , ///
        mcolor(orange) msize(vsmall)) ///
	(scatter rgRatioAvg year , ///
        mcolor(gs8) msize(vsmall)) ///
    (line rgRatio year if country == "Cyprus", ///
        lcolor(blue%50) lwidth(medium)) ///
    (line rgRatio year if country == "Greece", ///
        lcolor(green%50) lwidth(medium)) ///
    (line rgRatio year if country == "Portugal", ///
        lcolor(purple%50) lwidth(medium)) ///
	(line rgRatio year if country == "Italy", ///
        lcolor(orange%50) lwidth(medium)) ///
	(line rgRatioAvg year, ///
        lcolor(black%50) lwidth(medium)), ///
    xtitle("Year") ///
    ytitle("rgRatio") ///
    graphregion(color(white)) ///
    legend(order(1 "Cyprus" 2 "Greece" 3 "Portugal" 4 "Italy" 5 "EU Average") ) ///
    aspectratio(0.5)
}
graph export "Output\Figure7.pdf", replace

//Figure 8==============================================================
*title "Tax Burden and Debt Level (20 countries, 1999-2024)"
use "Data\cleaned_data\Analysis_3.dta", clear
count if tax!=.
count if tax<0

gen taoToRevenue = -tax/revenue *100
summarize taoToRevenue
drop if assistanceYear == 1
summarize taoToRevenue

gen wToGDP = w / gdp *100
/*
twoway (scatter taoToGDP wToGDP , mcolor(gs8) msize(vsmall)), ///
	   xtitle("Debt Level to GDP Ratio") ///
		ytitle("Tax to GDP Ratio")
*/

{
* Get the 99th percentile cutoff
egen p95 = pctile(wToGDP), p(95)

* Winsorize: cap values above p99
gen wToGDP_w = cond(wToGDP > p95, p95, wToGDP)
drop p95
* Get the 95th percentile cutoff
egen p95 = pctile(taoToRevenue), p(95)

* Winsorize: cap values above p95
gen taoToRevenue_w = cond(taoToRevenue > p95, p95, taoToRevenue)
drop p95


* Generate split variables
* Set cutoff
local cutoff = 60
gen w_left = wToGDP_w if wToGDP_w <= `cutoff'
gen w_right = wToGDP_w if wToGDP_w > `cutoff'
gen ylow =-0.3
gen yhigh =1.5
twoway ///
    (scatter taoToRevenue_w wToGDP_w, mcolor(gs8) msize(tiny)) ///
    (lfit taoToRevenue_w w_left, lcolor(blue%50)) ///
    (lfit taoToRevenue_w w_right, lcolor(red%50)), ///
    xline(`cutoff', lpattern(solid) lcolor(gs10)) ///
    xtitle("Debt Level to GDP Ratio (%)") ///
    ytitle("Tax to Revenue Ratio (%)") ///
	ylabel(0(0.5)1.5) ///
    legend(position(6) ring(1) cols(1) order(2 "Line of Best-Fit (debt level below 60% of gdp)" 3 "Line of Best-Fit (debt level above 60% of gdp)"))
*slopes
reg taoToRevenue_w w_left
reg taoToRevenue_w w_right
}
*as expected from the tax function, tax has a positive correlation with debt level
graph export "Output\Figure8.pdf", replace

//Figure 9================================================
*title "Tax Burden and Financial Distress (20 countries, 1999-2024)"
use "Data\cleaned_data\Analysis_3.dta", clear
merge m:1 year using "Data\cleaned_data/CISS.dta"
drop _merge
replace CISSIndex = CISSIndex*100
xtset country_id year
*lagging the instability index because the countries's borrowing/spending response comes after enough distress is initially present in the market
gen L1_CISSIndex = L1.CISSIndex
replace CISSIndex = L1_CISSIndex
summarize CISSIndex, detail
local cutoff50 = 14.3068
local cutoff90 = 33.03849

*gen CISSIndex_left = CISSIndex if CISSIndex < `cutoff50'
*gen CISSIndex_middle = CISSIndex if CISSIndex < `cutoff90' & CISSIndex >= `cutoff50'
*gen CISSIndex_right = CISSIndex if CISSIndex >= `cutoff90'

gen taoToRevenue = -t/revenue *100
{
* Get the 95th percentile cutoff
egen p95 = pctile(taoToRevenue), p(95)
* Winsorize: cap values above p95
gen taoToRevenue_w = cond(taoToRevenue > p95, p95, taoToRevenue)
drop p95
twoway ///
    (scatter taoToRevenue_w CISSIndex, mcolor(gs8) msize(tiny)) ///
	(lfit taoToRevenue_w CISSIndex, lcolor(red%50)), ///
    ytitle("Tax to Revenue Ratio (%)") ///
	xline(14.3068, lpattern(solid) lcolor(gs10)) ///
	xline(33.03849, lpattern(dash) lcolor(gs10)) ///
	legend(position(6) ring(1) cols(1) order(2 "Line of Best-Fit"))
}
reg taoToRevenue_w CISSIndex

graph export "Output\Figure9.pdf", replace

//Figure 10=================================================
*title "Debt Level Estimation Structural Break After Covid(20 countries, 1999-2023)"
use "Data\cleaned_data\Analysis_3.dta", clear
gen wToGDP = w / gdp *100
* Get the 99th percentile cutoff
egen p95 = pctile(wToGDP), p(95)

* Winsorize: cap values above p99
gen wToGDP_w = cond(wToGDP > p95, p95, wToGDP)
drop p95

local cutoff = 2020
gen w_left = year if year <= `cutoff'
gen w_right = year if year >= `cutoff'
twoway ///
    (scatter wToGDP_w year if inrange(year, 1999, 2023), mcolor(gs8) msize(tiny)) ///
	(lfit wToGDP_w w_left if inrange(year, 1999, 2023), lcolor(blue%50)) ///
	(lfit wToGDP_w w_right if inrange(year, 1999, 2023), lcolor(red%50)), ///
	xtitle("Year") ///
	xline(`cutoff', lpattern(solid) lcolor(gs10)) ///
    ytitle("Debt to GDP Ratio (%)") ///
	legend(position(6) ring(1) cols(1) ///
	order(2 "Line of Best-Fit (before 2020)" 3 "Line of Best-Fit (after 2020)"))

reg wToGDP_w w_left if inrange(year, 1999, 2023)
reg wToGDP_w w_right if inrange(year, 1999, 2023)
graph export "Output\Figure10.pdf", replace
*chow test?

reg wToGDP_w year if inrange(year, 1999, 2020)
estimates store pre

reg wToGDP_w year if inrange(year, 2020, 2023)
estimates store post

suest pre post
esttab pre post using "Output\Table2.tex", ///
    se star(* 0.10 ** 0.05 *** 0.01) ///
    title(SUEST Regression Results: Debt Level Estimation Pre vs Post 2020) ///
    label replace ///
    alignment(D{.}{.}{-1}) ///
    varlabels(year "Year" _cons "Constant") ///
	mtitles("Pre" "Post") ///
    compress

test [pre_mean]year = [post_mean]year



//Appendix: Figure A1============================================
*title "Tax Burden to Euro Currency Competitiveness (%, 20 Countries, 1999-2024)"
use "Data\cleaned_data\Analysis_3.dta", clear
merge m:1 year using "Data/cleaned_data/Euro_USDExchangeRate.dta"
*this is euro per usd. 
drop _merge

summarize euro_usdEXAvgAnnual, detail

gen taoToRevenue = -t/revenue *100

{
* Get the 95th percentile cutoff
egen p95 = pctile(taoToRevenue), p(95)
* Winsorize: cap values above p95
gen taoToRevenue_w = cond(taoToRevenue > p95, p95, taoToRevenue)
drop p95
twoway ///
    (scatter taoToRevenue_w euro_usdEXAvgAnnual, mcolor(gs8) msize(tiny)) ///
	(lfit taoToRevenue_w euro_usdEXAvgAnnual, lcolor(red%50)), ///
    xtitle("USD to Euro Spot Exchange Rate") ///
    ytitle("Tax to Revenue Ratio (%)") ///
		legend(position(6) ring(1) cols(1) order(2 "Line of Best-Fit")) ///
	xline(.8777137 , lpattern(solid) lcolor(gs10)) ///
	xline(.9657135, lpattern(dash) lcolor(gs10)) 
}
reg taoToRevenue_w euro_usdEXAvgAnnual
graph export "Output\FigureA1.pdf", replace

//Apendix: Figure A2 =============================
*title "PEPP Amount to GDP Ratio (Selected Countries, 2020-2024)"
use "Data/cleaned_data/PEPPAmounttemp.dta", clear

merge 1:1 country year using "Data/cleaned_data/CountryGDP.dta"
destring year, replace
keep if covidAssistanceAmount>0 & covidAssistanceAmount!=.
egen gdpAvg = mean(gdp), by(year)
replace gdp = gdpAvg if country=="Supranationals"

*a percentage:
gen covidAssistanceAmountOverGDP=covidAssistanceAmount/gdp*100
drop _merge totalCurrentHoldings gdp gdpAvg

*plotting, normalized by GDP
{
twoway ///
    (scatter covidAssistanceAmountOverGDP year if country == "Germany", ///
        mcolor(blue) msize(vsmall)) ///
    (scatter covidAssistanceAmountOverGDP year if country == "Greece", ///
        mcolor(green) msize(vsmall)) ///
    (scatter covidAssistanceAmountOverGDP year if country == "Italy", ///
        mcolor(orange) msize(vsmall)) ///
    (scatter covidAssistanceAmountOverGDP year if country == "Supranationals", ///
        mcolor(gs10) msize(vsmall)) ///
    (line covidAssistanceAmountOverGDP year if country == "Germany", ///
        lcolor(blue%50) lwidth(medium)) ///
    (line covidAssistanceAmountOverGDP year if country == "Greece", ///
        lcolor(green%50) lwidth(medium)) ///
    (line covidAssistanceAmountOverGDP year if country == "Italy", ///
        lcolor(orange%50) lwidth(medium)) ///
    (line covidAssistanceAmountOverGDP year if country == "Supranationals", ///
        lcolor(gs10%50) lwidth(medium)) , ///
    ///
    xtitle("Year") ///
    ytitle("PEPP Assistance Amount to GDP Ratio (%)") ///
    graphregion(color(white)) ///
    legend(position(6) ring (1) col(2) order(1 "Germany" 2 "Greece" 3 "Italy" 4 "Supranationals*") ) ///
    aspectratio(0.5)
}
graph export "Output\FigureA2.pdf", replace
*plotting the raw amount instead
/*
replace covidAssistanceAmount = covidAssistanceAmount/1000000000

{
twoway ///
    (scatter covidAssistanceAmount year if country == "Germany", ///
        mcolor(blue) msize(vsmall)) ///
    (scatter covidAssistanceAmount year if country == "Greece", ///
        mcolor(green) msize(vsmall)) ///
    (scatter covidAssistanceAmount year if country == "Italy", ///
        mcolor(orange) msize(vsmall)) ///
    (scatter covidAssistanceAmount year if country == "Supranationals", ///
        mcolor(gs10) msize(vsmall)) ///
    (line covidAssistanceAmount year if country == "Germany", ///
        lcolor(blue%50) lwidth(medium)) ///
    (line covidAssistanceAmount year if country == "Greece", ///
        lcolor(green%50) lwidth(medium)) ///
    (line covidAssistanceAmount year if country == "Italy", ///
        lcolor(orange%50) lwidth(medium)) ///
    (line covidAssistanceAmount year if country == "Supranationals", ///
        lcolor(gs10%50) lwidth(medium)) , ///
    ///
    xtitle("Year") ///
    ytitle("PEPP Assistance Amount (bn Euro)") ///
    graphregion(color(white)) ///
    legend(position(6) ring (1) col(2) order(1 "Germany" 2 "Greece" 3 "Italy" 4 "Supranationals") ) ///
    aspectratio(0.5)
}
*/